Micron Document
🎖️GitЯра🎖️

Commit 0fccf54462a2476c40357113a8c0f4e2df6dc542


Parents : 32df44f
Author : James Rich <2199651+jamesarich@users.noreply.github.com>
Signature : Signature validation error
Date : 2026-05-20T10:47:33-07:00
Committer : GitHub <noreply@github.com>
Date : 2026-05-20T12:47:33-05:00

fix(flatpak): route JitPack com.github group to jitpack.io primaryUrl (#5541)

Changes

2 files changed, 27 insertions(+), 7 deletions(-)


Diff

diff --git a/.agent_memory/session_context.md b/.agent_memory/session_context.md
index 13e5cfcfcc..64cecb3172 100644
--- a/.agent_memory/session_context.md
+++ b/.agent_memory/session_context.md
@@ -3,6 +3,12 @@
# Do NOT edit or remove previous entries — stale state claims cause agent confusion.
# Format: ## YYYY-MM-DD — <summary>
+## 2026-05-20 — Resolved Flatpak jitpack.io dependency download 404s in sandboxed offline builds
+- Modified `GenerateFlatpakSourcesTask` in `gradle/flatpak.gradle.kts` to dynamically detect dependency groups starting with `com.github.` (which are hosted on JitPack).
+- Configured the generation of `primaryUrl` for these dependencies to resolve directly from `https://jitpack.io` and created custom high-availability fallback lists.
+- Verified that compiling the desktopApp and running the flatpak generator task (`./gradlew :desktopApp:assemble :generateFlatpakSourcesFromCache --no-configuration-cache`) successfully produces a valid 10MB `flatpak-sources.json` containing correctly mapped JitPack URLs.
+- Ran quality and validation checks: `./gradlew spotlessCheck detekt` (100% SUCCESSFUL with zero issues).
+
## 2026-05-20 — Replaced standalone translations landing page with dynamic global header language switcher dropdown
- Deleted redundant standalone page `docs/en/translations.md` and updated `docs/README.md` to reflect layout change.
- Completely re-engineered `docs/_includes/language_switcher.html` to:

diff --git a/gradle/flatpak.gradle.kts b/gradle/flatpak.gradle.kts
index 6be63cb9ed..b3bb953fdb 100644
--- a/gradle/flatpak.gradle.kts
+++ b/gradle/flatpak.gradle.kts
@@ -62,13 +62,27 @@ abstract class GenerateFlatpakSourcesTask : DefaultTask() {
val sha256 = calculateSha256(file)
- val primaryUrl = "https://repo.maven.apache.org/maven2/$mavenPath"
- val mirrorUrls = listOf(
- "https://dl.google.com/dl/android/maven2/$mavenPath",
- "https://plugins.gradle.org/m2/$mavenPath",
- "https://maven-central.storage-download.googleapis.com/maven2/$mavenPath",
- "https://maven.aliyun.com/repository/public/$mavenPath"
- )
+ val isJitpack = group.startsWith("com.github.")
+ val primaryUrl = if (isJitpack) {
+ "https://jitpack.io/$mavenPath"
+ } else {
+ "https://repo.maven.apache.org/maven2/$mavenPath"
+ }
+
+ val mirrorUrls = if (isJitpack) {
+ listOf(
+ "https://repo.maven.apache.org/maven2/$mavenPath",
+ "https://maven-central.storage-download.googleapis.com/maven2/$mavenPath",
+ "https://maven.aliyun.com/repository/public/$mavenPath"
+ )
+ } else {
+ listOf(
+ "https://dl.google.com/dl/android/maven2/$mavenPath",
+ "https://plugins.gradle.org/m2/$mavenPath",
+ "https://maven-central.storage-download.googleapis.com/maven2/$mavenPath",
+ "https://maven.aliyun.com/repository/public/$mavenPath"
+ )
+ }
entries.add(
mapOf(

Served by rngit 1.5.0 - Generated in 0.05s